home *** CD-ROM | disk | FTP | other *** search
/ Workbench Add-On / Workbench Add-On - Volume 1.iso / Gfx / Edit / TSMorph / src / rexx / PostAnim.TSM < prev    next >
Text File  |  1994-10-30  |  887b  |  37 lines

  1. /* example Postscript script file for TSMorph */
  2. /* This uses MKANIM to generate an Animation  */
  3. /*
  4.  * Assumes frames are 1..n and first and last
  5.  * frames are being rendered.
  6.  *
  7.  * Output file is t:TSM_Anim
  8.  */
  9. /* $VER: PostAnim_TSM 2.5 (6.2.94)
  10.  */
  11. parse arg Frame TotalFrames Single FileName
  12. /* Frame       - current frame number starting from Start frame
  13.  * TotalFrames - total number of frames
  14.  * Single      - 1 for Single image warp, 0 for two image morph, 2 for Anim Morph, 3 for Anim Warp
  15.  * FileName    - Name of 24 bit image just produced
  16.  */
  17.  
  18. if (Frame = 0) then do
  19.     if ~open('tsmfile','t:tsm_genanim','w') then do
  20.         return 10
  21.     end
  22. end
  23. else do
  24.     if ~open('tsmfile','t:tsm_genanim','a') then do
  25.         return 10
  26.     end
  27. end
  28.  
  29. call writeln('tsmfile','10 '||FileName)
  30. call close('tsmfile')
  31.  
  32. if (Frame = TotalFrames+1) then do
  33.     address command "mkanim t:tsm_genanim t:TSM_Anim"
  34. end
  35.  
  36. exit
  37.